-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
feat: add cookies.setSerialized
to create a cookie from a string
#13681
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
cookies.setFromString
to create a cookie from a string
🦋 Changeset detectedLatest commit: 31de519 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
I edited the PR description. If you say "fixes" or "closes" followed by the issue number then GitHub will link the issue and PR |
The thrown errors for validation make me a bit wary of whether want to add this - feels a bit safer to parse the cookie from a string, then set it - that way you're forced to handle this yourself and TypeScript can help you. |
@dummdidumm it may be my lack of typescript expertise speaking here, but how would typescript help? |
Hey @benmccann, your suggestions make sense to me. Should I just commit them, or should we wait for another maintainer? |
I don't think there's much harm in adding my suggestions, but we'll need agreement for a larger group of maintainers before deciding whether to accept the PR |
Okay, I'll commit them. And what is your approach for PRs to be merged? Are we just waiting for enough maintainers to see this or you guys have some email/tag if opinion of others is required? |
Co-authored-by: Ben McCann <[email protected]>
Co-authored-by: Ben McCann <[email protected]>
Co-authored-by: Ben McCann <[email protected]>
Co-authored-by: Ben McCann <[email protected]>
Co-authored-by: Ben McCann <[email protected]>
Co-authored-by: Ben McCann <[email protected]>
cookies.setFromString
to create a cookie from a stringcookies.setSerialized
to create a cookie from a string
closes #13680
Please don't delete this checklist! Before submitting the PR, please make sure you do the following:
Tests
pnpm test
and lint the project withpnpm lint
andpnpm check
Changesets
pnpm changeset
and following the prompts. Changesets that add features should beminor
and those that fix bugs should bepatch
. Please prefix changeset messages withfeat:
,fix:
, orchore:
.Edits